package org.zk.entity;

import lombok.Data;

//扩展了imgUrl属性
@Data
public class GoodsExt2 {

    private Integer id;
    private String name;
    private String describle;
    private Float price;
    private String startTime;
    private String imgUrl;
    private String endTime;
    private String polishTime;
    private Float realPrice;
    private String catelog;

    public GoodsExt2() {
    }

    public GoodsExt2(Goods goods) {

        this.id = goods.getId();
        this.name = goods.getName() != null?goods.getName():"";
        this.describle = goods.getDescrible()!= null?goods.getDescrible():"";
        this.price = goods.getPrice();
        this.startTime = goods.getStartTime()!= null?goods.getStartTime():"";
        this.endTime = goods.getEndTime()!= null?goods.getEndTime():"";
        this.polishTime = goods.getPolishTime()!= null?goods.getPolishTime():"";
        this.realPrice = goods.getRealPrice()!=null?goods.getRealPrice():0;
    }

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDescrible() {
        return describle;
    }

    public void setDescrible(String describle) {
        this.describle = describle;
    }

    public Float getPrice() {
        return price;
    }

    public void setPrice(Float price) {
        this.price = price;
    }

    public String getStartTime() {
        return startTime;
    }

    public void setStartTime(String startTime) {
        this.startTime = startTime;
    }

    public String getImgUrl() {
        return imgUrl;
    }

    public void setImgUrl(String imgUrl) {
        this.imgUrl = imgUrl;
    }

    public String getEndTime() {
        return endTime;
    }

    public void setEndTime(String endTime) {
        this.endTime = endTime;
    }

    public String getPolishTime() {
        return polishTime;
    }

    public void setPolishTime(String polishTime) {
        this.polishTime = polishTime;
    }

    public Float getRealPrice() {
        return realPrice;
    }

    public void setRealPrice(Float realPrice) {
        this.realPrice = realPrice;
    }

    public String getCatelog() {
        return catelog;
    }

    public void setCatelog(String catelog) {
        this.catelog = catelog;
    }
}
